export interface City {
  id: number;
  name: string;
  sort: number;
  status: number;
}

export interface VenueType {
  id: number;
  name: string;
}

// 营业时间
export interface BusinessHours {
  workday: {
    isOpen: boolean;
    openTime: string;
    closeTime: string;
  };
  weekend: {
    isOpen: boolean;
    openTime: string;
    closeTime: string;
  };
}

export interface Store {
  id: number;
  name: string;
  city_id: number;
  address: string;
  contact_person: string;
  phone: string;
  business_hours: string; // JSON string
  description: string;
  notice: string;
  status: number; // 1:营业中, 0:暂停营业
  images: string; // 主图
  banner: string; // 轮播图 (JSON string of URLs)
  facilities: string; // 设施 (JSON string of facility names)
  venue_types: string; // 场地类型 (JSON string of venue type IDs)
  created_at: number;
  updated_at: number;
  city?: City;
}

export interface StoreQuery {
  page?: number;
  pageSize?: number;
  name?: string;
  keyword?: string;
  cityId?: number;
  city_id?: number;
  status?: number;
}

export interface StoreListData {
  list: Store[];
  total: number;
}

export interface Venue {
  id: number;
  name: string;
  store_id: number;
  venue_type: string;
  capacity: number;
  area: number;
  hour_price: number;
  day_price: number;
  time_based_pricing?: string; // JSON string
  description?: string;
  facilities?: string; // JSON string
  images?: string; // JSON string
  status: number; // 1:空闲中, 2:使用中, 3:保洁中, 4:待保洁, 5:维护中
  sort_order?: number;
  opening_hours?: string;
  special_notice?: string;
  created_at: number;
  updated_at: number;
}

export interface VenueListData {
  list: Venue[];
  total: number;
}

export interface VenueQuery {
  page?: number;
  pageSize?: number;
  name?: string;
  store_id?: number;
  venue_type?: string;
  status?: number;
}

export interface TimeBasedPricing {
  start_time: string;
  end_time: string;
  price: number;
}

